/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package za.ac.cput.garethc.OCP.violation.service.impl;

import za.ac.cput.garethc.OCP.violation.model.Shape;
import za.ac.cput.garethc.OCP.violation.model.Square;
import za.ac.cput.garethc.OCP.violation.model.Triangle;
import za.ac.cput.garethc.OCP.violation.service.DrawService;

/**
 *
 * @author Gareth
 */
public class ShapeDrawService implements DrawService{

    @Override
    public void drawShape(Shape s) {
        switch (s.getS_type())
        {
            case 1: drawTriangle((Triangle)s);
            case 2: drawSquare((Square)s);
        }
    }

    @Override
    public void drawTriangle(Triangle t) {
        System.out.println("Drawing a triangle");
    }

    @Override
    public void drawSquare(Square sq) {
        System.out.println("Drawing a Square");
    }
    
}
